package com.example.pertecttime.activity.main;

import com.example.pertecttime.api.HttpMethosds;
import com.example.pertecttime.base.BaseResult;
import com.example.pertecttime.entity.test;
import com.example.pertecttime.tools.RxSchedulers;

import rx.Observable;

/**
 * Created by 半生瓜 on 2017/7/20.
 */

public class mainModle  implements mainContract.Model {
    private static mainModle model;
    public static mainModle getInstance() {
        if (model == null) {
            model = new mainModle();
        }
        return model;
    }

    @Override
    public Observable<BaseResult<test>> gettest(test test) {
        return HttpMethosds.getInstance().retrofitServicel
                .dotest(test)
                .compose(RxSchedulers.io_main());
    }
}
